package org.iron.services;

import org.apache.tapestry5.SymbolConstants;
import org.apache.tapestry5.ioc.MappedConfiguration;
import org.apache.tapestry5.ioc.ServiceBinder;
import org.got5.tapestry5.jquery.JQuerySymbolConstants;

public class AppModule
{
    public static void bind(ServiceBinder binder)
    {
        binder.bind(WeatherService.class, WeatherServiceImpl.class);
        binder.bind(NewBookService.class,NewBookServiceImpl.class);
        binder.bind(PrinterService.class,PrinterServiceImpl.class);       

    }

    public static void contributeApplicationDefaults(MappedConfiguration<String, Object> configuration)
    {
        configuration.add(SymbolConstants.COMPRESS_WHITESPACE, "false");
        // configuration.add(SymbolConstants.FILE_CHECK_INTERVAL, "1 s");
        configuration.add(SymbolConstants.MINIFICATION_ENABLED, "true");
        configuration.add(SymbolConstants.SUPPORTED_LOCALES, "en,zh_TW,zh_HK,zh_CN");
        configuration.add(SymbolConstants.PRODUCTION_MODE, "false");
        configuration.add(SymbolConstants.HMAC_PASSPHRASE, "rIbShOefrOze77SPy12niBS");
        configuration.add(JQuerySymbolConstants.SUPPRESS_PROTOTYPE, "false");
        configuration.add(JQuerySymbolConstants.JQUERY_ALIAS, "jq");

    }
}
